package main

import (
	"net/http"

	"github.com/gin-gonic/gin"
)

type User struct {
	Id       string `json:"id"`
	Username string `json:"username"`
	Password string `json:"password"`
}

func main() {
	var router = gin.Default()
	router.GET("/getValue", func(c *gin.Context) {
		var username = c.Query("username")
		var password = c.Query("password")
		var user = User{
			Id:       "1",
			Username: username,
			Password: password,
		}
		c.JSON(http.StatusOK, user)
	})
	router.Run(":8080")
}
